package com.ivo.activiti.bpmn.record;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.List;

/**
 * @author wj
 * @version 1.0
 */
@RestController
@RequestMapping("/node")
public class NodeController {

    @Resource
    private NodeService nodeService;

    @GetMapping("/getNode")
    Node getNode(String node) {
        return nodeService.getNode(node);
    }

    @PostMapping("/saveNode")
    void saveNodes(Node node) {
        nodeService.saveNode(node);
    }
}
